<%@ page contentType="text/html;charset=UTF-8" %>
<%@ include file="/WEB-INF/views/include/taglib.jsp"%>
<html>
<head>
	<title>维护记录管理</title>
	<meta name="decorator" content="default"/>
	<script type="text/javascript">
		$(document).ready(function() {
			
		});
		function page(n,s){
			$("#pageNo").val(n);
			$("#pageSize").val(s);
			$("#searchForm").submit();
        	return false;
        }
	</script>
</head>
<body>
	<ul class="nav nav-tabs">
		<li class="active"><a href="${ctx}/duty/zlmtMaintenanceRecord/">维护记录列表</a></li>
		<li><a href="${ctx}/duty/zlmtMaintenanceRecord/form">维护记录添加</a></li>
	</ul>
	<form:form id="searchForm" modelAttribute="zlmtMaintenanceRecord" action="${ctx}/duty/zlmtMaintenanceRecord/" method="post" class="breadcrumb form-search">
		<input id="pageNo" name="pageNo" type="hidden" value="${page.pageNo}"/>
		<input id="pageSize" name="pageSize" type="hidden" value="${page.pageSize}"/>
		<ul class="ul-form">
		<li><label>主机名：</label>
        		<form:input path="hostname" htmlEscape="false" maxlength="64" class="input-medium"/>
        	</li>
			<li><label>开始时间：</label>
				<input name="fromTime" type="text"  maxlength="20" class="input-medium Wdate "
					   value="<fmt:formatDate value="${zlmtMaintenanceRecord.fromTime}" pattern="yyyy-MM-dd"/>"
					   onclick="WdatePicker({dateFmt:'yyyy-MM-dd',isShowClear:false});"/>
			</li>
			<li><label>结束时间：</label>
				<input name="thruTime" type="text"  maxlength="20" class="input-medium Wdate "
					   value="<fmt:formatDate value="${zlmtMaintenanceRecord.thruTime}" pattern="yyyy-MM-dd"/>"
					   onclick="WdatePicker({dateFmt:'yyyy-MM-dd',isShowClear:false});"/>
			</li>
			<li class="btns"><input id="btnSubmit" class="btn btn-primary" type="submit" value="查询"/></li>
			<li class="clearfix"></li>
		</ul>
	</form:form>
	<sys:message content="${message}"/>
	<table id="contentTable" class="table table-striped table-bordered table-condensed">
		<thead>
			<tr>
				<th>主机名</th>
				<th>别名</th>
				<th>运维原因</th>
				<th>运维操作记录</th>
				<th>运维结果</th>
				<th>开始时间</th>
				<th>结束时间</th>
				<th>更新时间</th>
				<th>备注信息</th>
				<th>操作</th>
			</tr>
		</thead>
		<tbody>
		<c:forEach items="${page.list}" var="zlmtMaintenanceRecord">
			<tr>
			    <td><a href="${ctx}/duty/zlmtMaintenanceRecord/form?id=${zlmtMaintenanceRecord.id}">
			        ${zlmtMaintenanceRecord.hostname}
			        </a></td>
                <td>
			        ${zlmtMaintenanceRecord.alias}
			    </td>
			    <td>
                	${zlmtMaintenanceRecord.maintenanceReason}
                </td>
                 <td>
                	 ${zlmtMaintenanceRecord.maintenanceOperation}
                 </td>
                 <td>
                     ${zlmtMaintenanceRecord.maintenanceResult}
                 </td>
                 <td>
                 	<fmt:formatDate value="${zlmtMaintenanceRecord.updateDate}" pattern="yyyy-MM-dd HH:mm:ss"/>
                 </td>
                 <td>
                     <fmt:formatDate value="${zlmtMaintenanceRecord.fromTime}" pattern="yyyy-MM-dd HH:mm:ss"/>
                  </td>
				<td>
					<fmt:formatDate value="${zlmtMaintenanceRecord.thruTime}" pattern="yyyy-MM-dd HH:mm:ss"/>
				</td>
				<td>
					${zlmtMaintenanceRecord.remarks}
				</td>
			    <td>
    				<a href="${ctx}/duty/zlmtMaintenanceRecord/form?id=${zlmtMaintenanceRecord.id}">修改</a>
					<a href="${ctx}/duty/zlmtMaintenanceRecord/delete?id=${zlmtMaintenanceRecord.id}" onclick="return confirmx('确认要删除该维护记录吗？', this.href)">删除</a>
				</td>
			</tr>
		</c:forEach>
		</tbody>
	</table>
	<div class="pagination">${page}</div>
</body>
</html>